﻿#region

using System;
using System.Collections.Generic;
using Kaiser.Infrastructure.DomainBase;
using Kaiser.Modules.CMS.Domain.Enum;

#endregion

namespace Kaiser.Modules.CMS.Domain
{
    public class Article : EntityBase
    {
        /// <summary>
        /// 文章标识
        /// </summary>
        public string Code { get; set; }

        /// <summary>
        /// 文章作者
        /// </summary>
        public string Author { get; set; }
        
        /// <summary>
        /// 标题
        /// </summary>
        public string Title { get; set; }

        /// <summary>
        /// 副标题
        /// </summary>
        public string SecondTitle { get; set; }

        /// <summary>
        /// 文章关键字
        /// </summary>
        public string Keywords { get; set; }

        /// <summary>
        /// 链接地址
        /// </summary>
        public string Affix { get; set; }

        /// <summary>
        /// 引用地址
        /// </summary>
        public string SourceDerivation { get; set; }

        /// <summary>
        /// 来源作者
        /// </summary>
        public string SourceAuthor { get; set; }

        /// <summary>
        /// 引用地址
        /// </summary>
        public string SourceUrl { get; set; }

        /// <summary>
        /// 文章摘要
        /// </summary>
        public string ContentSummary { get; set; }

        /// <summary>
        /// 文章内容
        /// </summary>
        public string Content { get; set; }


        public IDictionary<int, string> ContentParntList { get; set; }

        /// <summary>
        /// 文章点击次数
        /// </summary>
        public int ClickCount { get; set; }

        /// <summary>
        /// 是否删除
        /// </summary>
        public bool IsDelete { get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>
        public DateTime CreateTime { get; set; }

        /// <summary>
        /// 更新时间
        /// </summary>
        public DateTime? UpdateTime { get; set; }

        /// <summary>
        /// 发布时间
        /// </summary>
        public DateTime? PublishTime { get; set; }

        public string Area { get; set; }

        /// <summary>
        /// 推荐
        /// </summary>
        public bool Groom { get; set; }


        /// <summary>
        /// 热门
        /// </summary>
        public bool IsHot { get; set; }


        /// <summary>
        /// 精华
        /// </summary>	
        public bool IsCream { get; set; }

        /// <summary>
        /// 滚动
        /// </summary>	
        public bool IsRoll { get; set; }

        /// <summary>
        /// 所属分类
        /// </summary>
        public IList<Category> Category { get; set; }

        /// <summary>
        /// 文章图片
        /// </summary>
        public IList<Photo> Photos { get; set; }


        /// <summary>
        /// 文章附件
        /// </summary>
        public IList<Attach> Files { get; set; }

        /// <summary>
        /// 文章评论
        /// </summary>
        public IList<Common> Commons { get; set; }

        /// <summary>
        /// 访问人数
        /// </summary>
        public int VisitorsCount { get; set; }


        /// <summary>
        /// 上一篇文章
        /// </summary>
        public Article PreArticle { get; set; }

        /// <summary>
        /// 下一篇文章
        /// </summary>
        public Article NextArticle { get; set; }

        /// <summary>
        /// 相关热词
        /// </summary>
        public string Tag { get; set; }

        /// <summary>
        /// 延生阅读列表
        /// </summary>
        public IList<Article> ExtendedReading { get; set; }

        /// <summary>
        /// 设置指定
        /// </summary>
        public void SetTop()
        {
            //todo 设置指定
        }

        /// <summary>
        /// 设置滚动
        /// </summary>
        public void SetRoll()
        {
            //todo 设置滚动
        }

        /// <summary>
        /// 设置精华
        /// </summary>
        public void Cream()
        {
            //todo 设置精华
        }

       /// <summary>
       /// 设置为热门
       /// </summary>
        public void SetHot()
        {
            //todo 设置为热门
        }

        /// <summary>
        /// 设置为推荐
        /// </summary>
        public void SetGroom()
        {
            //todo 设置为推荐
        }

        public void SetPreArticle(Article article)
        {
            //todo 设置上一篇文章
        }

        public void SetNextArticle(Article article)
        {
            //todo 设置下一篇文章
        }

        public void SetContentParntList(int index,string content)
        {
            //todo 设置文段段落内容(就是可以分页显示内容那种)
        }
    }
}